<%--
  Created by IntelliJ IDEA.
  User: LiuXiaoChuan
  Date: 2022/5/23
  Time: 9:38
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<html>
<head>
    <title>Title</title>
    <link rel="stylesheet" href="${pageContext.request.contextPath}/static/layui/css/layui.css">
    <script type="text/javascript" src="${pageContext.request.contextPath}/static/layui/layui.js"></script>
    <script type="text/javascript" src="${pageContext.request.contextPath}/static/js/jquery-3.5.1.min.js"></script>
    <script type="text/javascript" src="${pageContext.request.contextPath}/static/js/ajaxForm.js"></script>
    <script>
        layui.use(['form','laydate','layer','jquery'],function () {
            var form = layui.form,laydate=layui.laydate,layer=layui-layer,$=layui.jquery;


            //监听表单的提交
            form.on('submit(formBtn)',function () {
                $("#form1").ajaxSubmit({
                    type: "post",
                    url:'${pageContext.request.contextPath}/et/ydbmfupd',
                    success:function (data) {
                        var index = parent.layer.getFrameIndex(window.name);//获得frame索引
                        parent.layer.close(index);//关闭当前frame
                        parent.layui.table.reload('titleEt');//可以对父窗口进行刷新
                    }
                });
                return false;
            });

        });
    </script>
</head>
<body>
<form class="layui-form" id="form1" lay-filter="form1" enctype="multipart/form-data">

    <input type="hidden" name="enrollmentId"  class="layui-input" value="${enrollmentId1.enrollmentId}" />

    <div class="layui-form-item">
        <label class="layui-form-label">预定报名费</label>
        <div class="layui-input-inline">
            <input type="text" name="amount" lay-verify="required|number"
                   autocomplete="off" class="layui-input" value="${enrollmentId1.amount}"/>

        </div>
    </div>


    <%--        提交--%>
    <div class="layui-form-item">
        <div class="layui-input-block">
            <button id="formBtn" class="layui-btn" lay-submit lay-filter="formBtn">提交</button>
            <button type="reset" class="layui-btn layui-btn-primary">重置</button>
        </div>
    </div>
</form>

</body>
</html>
